package com.xiaowen.service;

import com.xiaowen.dao.UserMapper;
import com.xiaowen.model.User;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;



/**
 * Created by 15c on 2018/5/18.
 */
@Service("User")
public class UserServiceImpl implements UserService {
    @Autowired
   UserMapper userMapper;


    @Override
    public User showAUserById(Integer userId) {
        return userMapper.selectById(userId);
    }

    @Override
    public int add(User user) {
        return userMapper.insert(user);
    }
}
